import request from '@/utils/request'

export const getUserDatalibGroup = (user, vcode) => {
  return request({
    url: '/v1/administrator/datalib/group/',
    method: 'get',
    params: { user, vcode },
  })
}

export const createUserDatalibGroup = (data) => {
  return request({
    url: '/v1/administrator/datalib/group/',
    method: 'post',
    data,
  })
}

export const getUserGroupIndex = (gid) => {
  return request({
    url: '/v1/administrator/datalib/groupIndex/',
    method: 'get',
    params: { gid },
  })
}

export const createUserGroupIndex = (data) => {
  return request({
    url: '/v1/administrator/datalib/groupIndex/',
    method: 'post',
    data,
  })
}
